/*
 * @Author: Setsuna
 * @Email: setsuna.xyz@qq.com
 * @FilePath: \src\components\PhotoViewSimple\index.tsx
 * @Date: 2022-04-13 15:06:06
 * @LastEditTime: 2022-05-26 14:58:31
 */

import React from 'react'
import { PhotoSlider } from 'react-photo-view'

function PhotoView(props) {
  let { visible, images = [], onClose } = props

  return (
    <>
      <PhotoSlider
        images={images.map(item => ({ src: item, key: item }))}
        visible={visible}
        onClose={onClose}
        index={0}
      />
    </>
  )
}

export default React.memo(PhotoView)
